package cn.com.git.admin.common;


import cn.com.git.admin.service.dto.AuthenticationDTO;

/**
 * upms系统常量类
 * Created by shuzheng on 2017/2/18.
 */
public class UpmsConstant {


    public static final String UPMS_TYPE = "upms.type";

    /**
     * cache key 缓存 key
     */
    //全局session id
    public static final String UPMS_SERVER_SESSION_ID = "upms-server-session-id";
    //局部session id
    public static final String UPMS_CLIENT_SESSION_ID="upms-client-session-id";
    //全局code
    public static final String UPMS_SERVER_CODE = "upms-server-code";

    //客户端 session 超时时间 一小时
    public static final Long UPMS_CLIENT_SESSION_TIMEOUT = 60*60*1000L;

    /**
     * session key
     */
    public static final String SESSION_SYS_USER = "sysUser";

    /**
     * 超级管理员账号
     */
    public static final String SUPER_ADMIN_ACCOUNT= "superadmin";

    /**
     * 超级管理员
     */
    public static AuthenticationDTO SUPER_ADMIN = new AuthenticationDTO () ;
    static{
        AuthenticationDTO.SysUser user = new AuthenticationDTO.SysUser();
        user.setId(0);
        user.setAccount(SUPER_ADMIN_ACCOUNT);
        user.setPassword("1C63129AE9DB9C60C3E8AA94D3E00495");
        user.setName("超级管理员");
        SUPER_ADMIN.setSysUser(user);
    }

}
